<!--
  @author tanghongjun
  @since 2019年8月20日
-->
<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<div class="layui-card-body" th:fragment="query">
    <div class="zmn-form-item">
        <div class="item-inline">
            <label class="inline-label">子公司：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select name="companyId" id="companyId" lay-filter="companyId" lay-verify=""
                                lay-search="">
                            <option value="">-选择-</option>
                            <zmn th:each="comp:${comps}">
                                <option th:value="${comp.companyId}" th:text="${comp.name}"
                                        th:selected="${comp.companyId == vo.companyId}">
                                </option>
                            </zmn>
                        </select>
                    </div>
                </div>
            </div>
        </div>
        <div class="item-inline">
            <label class="inline-label">服务公司：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select name="manageCompanyId" id="manageCompanyId" lay-filter="manageCompanyId" lay-verify=""
                                lay-search="">
                            <option value="">-选择-</option>
                            <zmn th:each="comp:${manageComps}">
                                <option th:value="${comp.companyId}" th:text="${comp.name}"
                                        th:selected="${comp.companyId == vo.manageCompanyId}">
                                </option>
                            </zmn>
                        </select>
                    </div>
                </div>
            </div>
        </div>
        <div class="item-inline">
            <label class="inline-label">省：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select name="provinceId" id="provinceId" lay-filter="provinceId" lay-search>
                            <option value="">-选择-</option>
                            <option th:each="province:${provinces}" th:value="${province.areaId}"
                                    th:selected="${province.areaId == vo.provinceId}" th:text="${province.name}"></option>
                        </select>
                    </div>
                </div>
            </div>
        </div>
        <div class="item-inline">
            <label class="inline-label">市：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select name="cityId" id="cityId" lay-filter="cityId" lay-search>
                            <option value="">-选择-</option>
                            <option th:each="city:${citys}" th:value="${city.areaId}"
                                    th:selected="${city.areaId == vo.cityId}" th:text="${city.name}"></option>
                        </select>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <div class="zmn-form-item">
        <div class="item-inline">
            <label class="inline-label">区：</label>
            <div class="inline-box">
                <div class="inline-box-cc">
                    <div class="box-input-inline">
                        <select name="countyIds" xm-select="countyId" id="countyId" lay-filter="countyId">
                            <option value="">-选择-</option>
                        </select>
                    </div>
                </div>
            </div>
        </div>
        <div class="item-submit">
            <button class="layui-btn layui-btn-sm" onclick="return addArea();" lay-event="add"
                    th:if="${#authPermit.checkPermit('/company/area/add.action')}">开通区域
            </button>
            <button class="layui-btn layui-btn-sm" lay-submit="" lay-filter="zmn-form-submit"><i class="layui-icon">&#xe615;</i></button>
        </div>
    </div>

</div>
</html>